from django.conf.urls.defaults import *
from django.contrib.auth.views import login, logout

#from uwaterloo.views import current_datetime
#from uwaterloo.views import hours_ahead

#from uwaterloo.views import search

from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns('',
	
	(r'^admin/(.*)', admin.site.root),
	(r'^register/$', "myuwaterloo.register.views.register"),
	(r'^register/thanks/$', "myuwaterloo.register.views.thanks"),
	(r'^search/$', "myuwaterloo.search.views.search"),

	#(r'^rate_class/', "uwaterloo.rateClasses.views.findclass"),
	(r'^about$', "myuwaterloo.about.views.about"),
	(r'^contact/$', "myuwaterloo.contact.views.contact"),
	(r'^accounts/login/$',  login),
    (r'^accounts/logout/$', "myuwaterloo.logout.views.log_out"), #need to turn this into a custom field###
	(r'^accounts/profile/$', "myuwaterloo.userprofile.views.profile"),
	
	# URLS FOR CLASS DISPLAY ######
	(r'^(\w\w\w\w)+(\d\d\d)/',"myuwaterloo.classdisplay.views.classdisplay"),
	(r'^(\w\w\w)+(\d\d\d)/',"myuwaterloo.classdisplay.views.classdisplay"),
	(r'^(\w\w)+(\d\d\d)/',"myuwaterloo.classdisplay.views.classdisplay"),
	(r'^(\w\w\w\w\w)+(\d\d\d)/',"myuwaterloo.classdisplay.views.classdisplay"),
	(r'^(\w\w\w\w)+(\d\d\d\w)/',"myuwaterloo.classdisplay.views.classdisplay"),
	(r'^(\w\w\w\w\w)+(\d\d\d\w)/',"myuwaterloo.classdisplay.views.classdisplay"),
	#Goes to the homepage if there is nothing#
	('^$', "myuwaterloo.home.views.display"),
)
